package org.example;

public class MaoPaoPaiXu {
    public static void main(String[] args){
        int[] arr = {3,2,15,34,78,23,12,56,100,99,90,22};

        int temp = 0;
        for(int i = 0;i < arr.length - 1;i++){
            for(int j = 0;j <  arr.length - i - 1;j++){
                if(arr[j] > arr[j+1]){
                    temp = arr[j];
                    arr[j] = arr[j+1];
                    arr[j+1] = temp;
                }
            }
        }
        System.out.println("长度大小为："+arr.length);
        for(int res : arr){
            System.out.println(res);
        }
    }
}
